﻿Namespace Diagnostics.Profiler.Recorder
    Public NotInheritable Class ProfilerRecord
        Private _count As Integer
        Private _callSpan As TimeSpan

        Public Sub New(ByVal callSpan As TimeSpan)
            _count = 1
            _callSpan = callSpan
        End Sub

        Public Sub Add(ByVal callSpan As TimeSpan)
            _count += 1
            _callSpan += callSpan
        End Sub

        Public ReadOnly Property Count() As Integer
            Get
                Return _count
            End Get
        End Property

        Public ReadOnly Property CallSpan() As TimeSpan
            Get
                Return _callSpan
            End Get
        End Property
    End Class
End Namespace
